package com.ruoyi.common.utils.shormsg;

import com.alibaba.fastjson2.JSONObject;
import com.alibaba.fastjson2.annotation.JSONField;

import lombok.Data;
import lombok.experimental.Accessors;

/**
*
* @author liuz
*/
@Data
@Accessors(chain = true)
public class SmsSendResult {

//  CommoneResponse.data  {"Message":"账户余额不足","RequestId":"9881FC95-28C3-499C-B15F-63AEBA1BA832","Code":"isv.AMOUNT_NOT_ENOUGH"}

  @JSONField(name = "Message")
  private String message;

  @JSONField(name = "RequestId")
  private String requestId;

  @JSONField(name = "Code")
  private String code;

  @JSONField(name = "BizId")
  private String bizId;

  public boolean isSuccess() {
      return "ok".equalsIgnoreCase(code);
  }

  @Override
  public String toString(){
      return JSONObject.toJSONString(this);
  }

}
